package com.loop.view;

import android.content.Context;
import android.support.annotation.NonNull;
import android.support.design.widget.TabLayout;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;

/**
 * @author: ZengZhenHua
 * @date: 2018/12/19
 * @email: cengzhenghua@163.com
 */
public class ClosableTabLayout extends TabLayout{
    public ClosableTabLayout(Context context) {
        super(context);
    }

    public ClosableTabLayout(Context context, AttributeSet attrs) {
        super(context, attrs);
    }

    @NonNull
    @Override
    public Tab newTab() {
        Tab tab = super.newTab();
        View view =LayoutInflater.from(getContext()).inflate(R.layout.closable_tab,null);
        return tab;
    }
}
